package com.tgg.treeproject.utils;

import java.util.Random;

public class NumberUtils {

//获取6位随机数
public static  String getNumber6(){
    Random random = new Random();
    String result="";
    for (int i=0;i<6;i++)
    {
        result+=random.nextInt(10);
    }
    return result;
}
//进制转换
//num 要转换的数 importBase源数的进制 outBase要转换成的进制
public static String change(String num,Integer importBase,Integer outBase) {
    return new java.math.BigInteger(num, importBase).toString(outBase);
}


}
